<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>添加学生</title>
    {% load static %}
    <link rel="stylesheet" href="{% static 'css/add.css' %}">
</head>
<body>
<form method="post" action="">
    <h4>添加学生</h4>
    {% csrf_token %}
    <p>学生姓名：<input type="text" name="name" placeholder="请输入学生姓名" required></p>
    <p>学生性别：<select name="gender" id="gender">
        <option value="保密">保密</option>
        <option value="男">男</option>
        <option value="女">女</option>
    </select></p>
    <p>学生年龄：<input type="text" name="age" id="age" placeholder="请输入学生年龄" required></p>
    <p>入读时间<input type="datetime-local" name="study_time" id="study_time" placeholder="请输入入读时间" required></p>
    <p>就读班级：
        <select name="class_name_id" id="class_name">
            {% for i in classname %}
            <option value="{{ i.id }}">{{ i.name }}</option>
            {% endfor %}
        </select>
    </p>
    <input type="submit" value="提交" class="btn">
    <a href="{% url 'classmate:index' %}" class="btn">返回</a>
</form>
</body>
</html>